/*
 Navicat Premium Dump SQL

 Source Server         : 127.0.0.1
 Source Server Type    : MySQL
 Source Server Version : 80300 (8.3.0)
 Source Host           : 127.0.0.1:3306
 Source Schema         : hiss-basic

 Target Server Type    : MySQL
 Target Server Version : 80300 (8.3.0)
 File Encoding         : 65001

 Date: 27/05/2025 19:19:30
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for sys_dept
-- ----------------------------
DROP TABLE IF EXISTS `sys_dept`;
CREATE TABLE `sys_dept` (
                            `id` bigint NOT NULL AUTO_INCREMENT,
                            `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '部门名称',
                            `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
                            `sort` int DEFAULT '0' COMMENT '排序',
                            `parent_id` bigint DEFAULT '0' COMMENT '上级部门 id',
                            `leader_id` bigint DEFAULT NULL COMMENT '部门领导ID',
                            `enable_status` tinyint DEFAULT '0' COMMENT '启用状态：0 禁用 1 启用',
                            `create_time` datetime DEFAULT CURRENT_TIMESTAMP,
                            `update_time` datetime DEFAULT NULL,
                            PRIMARY KEY (`id`),
                            KEY `enable_status_idx` (`enable_status`) USING BTREE COMMENT '启用状态普通索引'
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统部门表';

-- ----------------------------
-- Records of sys_dept
-- ----------------------------
BEGIN;
INSERT INTO `sys_dept` (`id`, `name`, `remark`, `sort`, `parent_id`, `leader_id`, `enable_status`, `create_time`, `update_time`) VALUES (1, 'HB 科技发展有限公司', NULL, 0, 0, 1, 1, '2025-05-27 19:16:32', '2025-05-27 19:17:03');
COMMIT;

-- ----------------------------
-- Table structure for sys_dict
-- ----------------------------
DROP TABLE IF EXISTS `sys_dict`;
CREATE TABLE `sys_dict` (
                            `id` bigint NOT NULL AUTO_INCREMENT,
                            `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '字典名称',
                            `code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '字典编码',
                            `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
                            `enable_status` tinyint DEFAULT '0' COMMENT '启用状态',
                            `create_time` datetime DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
                            `update_time` datetime DEFAULT NULL COMMENT '更新时间',
                            PRIMARY KEY (`id`),
                            UNIQUE KEY `code_unique` (`code`) USING BTREE COMMENT '字典编码唯一索引',
                            KEY `enable_status_idx` (`enable_status`) USING BTREE COMMENT '启用状态普通索引'
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统字典表';

-- ----------------------------
-- Records of sys_dict
-- ----------------------------
BEGIN;
INSERT INTO `sys_dict` (`id`, `name`, `code`, `remark`, `enable_status`, `create_time`, `update_time`) VALUES (1, '启用状态', 'enable_status', NULL, 1, '2025-05-27 18:41:10', NULL);
COMMIT;

-- ----------------------------
-- Table structure for sys_dict_item
-- ----------------------------
DROP TABLE IF EXISTS `sys_dict_item`;
CREATE TABLE `sys_dict_item` (
                                 `id` bigint NOT NULL AUTO_INCREMENT,
                                 `label` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '字典标签',
                                 `value` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '字典键值',
                                 `color` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '标签颜色',
                                 `sort` int DEFAULT '0' COMMENT '排序',
                                 `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
                                 `dict_id` bigint DEFAULT NULL COMMENT '字典 ID',
                                 `enable_status` tinyint DEFAULT '0' COMMENT '启用状态：0 禁用 1 启用',
                                 `create_time` datetime DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
                                 `update_time` datetime DEFAULT NULL COMMENT '更新时间',
                                 PRIMARY KEY (`id`),
                                 KEY `dict_id_idx` (`dict_id`) USING BTREE COMMENT '字典ID普通索引',
                                 KEY `enable_status_idx` (`enable_status`) USING BTREE COMMENT '启用状态普通索引'
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统字典项表';

-- ----------------------------
-- Records of sys_dict_item
-- ----------------------------
BEGIN;
INSERT INTO `sys_dict_item` (`id`, `label`, `value`, `color`, `sort`, `remark`, `dict_id`, `enable_status`, `create_time`, `update_time`) VALUES (1, '禁用', '0', 'error', 0, NULL, 1, 1, '2025-05-27 18:41:10', NULL);
INSERT INTO `sys_dict_item` (`id`, `label`, `value`, `color`, `sort`, `remark`, `dict_id`, `enable_status`, `create_time`, `update_time`) VALUES (2, '启用', '1', 'green', 0, NULL, 1, 1, '2025-05-27 18:41:10', NULL);
COMMIT;

-- ----------------------------
-- Table structure for sys_login_log
-- ----------------------------
DROP TABLE IF EXISTS `sys_login_log`;
CREATE TABLE `sys_login_log` (
                                 `id` bigint NOT NULL AUTO_INCREMENT,
                                 `username` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '用户名',
                                 `os` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '操作系统',
                                 `browser` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '浏览器',
                                 `ip` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT 'ip 地址',
                                 `status` tinyint DEFAULT '0' COMMENT '登录状态：0 成功 1 失败',
                                 `login_time` datetime DEFAULT CURRENT_TIMESTAMP COMMENT '登录时间',
                                 `create_time` datetime DEFAULT CURRENT_TIMESTAMP,
                                 `update_time` datetime DEFAULT NULL,
                                 PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统登录日志';

-- ----------------------------
-- Records of sys_login_log
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_menu
-- ----------------------------
DROP TABLE IF EXISTS `sys_menu`;
CREATE TABLE `sys_menu` (
                            `id` bigint NOT NULL AUTO_INCREMENT,
                            `title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '菜单标题',
                            `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '路由名称',
                            `path` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '路由地址',
                            `component` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '组件路径',
                            `icon` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '菜单图标',
                            `authority` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '权限标识',
                            `menu_type` tinyint DEFAULT '0' COMMENT '菜单类型：0 目录 1 菜单 2 按钮',
                            `component_type` tinyint DEFAULT '0' COMMENT '组件类型：0 组件 1 内链 2 外链',
                            `link` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '链接，配合内链 外链使用',
                            `parent_id` bigint DEFAULT '0' COMMENT '父级菜单 ID',
                            `sort` int DEFAULT '0' COMMENT '排序',
                            `enable_status` tinyint DEFAULT '0' COMMENT '启用状态：0 禁用 1 启用',
                            `cache_status` tinyint DEFAULT '0' COMMENT '缓存状态：0 否 1 是',
                            `hidden_status` tinyint DEFAULT '0' COMMENT '显示状态：0 显示 1 隐藏 ',
                            `create_time` datetime DEFAULT CURRENT_TIMESTAMP,
                            `update_time` datetime DEFAULT NULL,
                            PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=45 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统菜单表';

-- ----------------------------
-- Records of sys_menu
-- ----------------------------
BEGIN;
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (1, '系统管理', 'System', '/system', '', 'lucide:settings', NULL, 0, 0, NULL, 0, 0, 1, 0, 0, '2025-05-27 18:43:44', '2025-05-27 18:46:43');
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (2, '用户管理', 'SystemUser', '/sys/user', '/system/user/index', NULL, 'sys:user:list-page', 1, 0, NULL, 1, 0, 1, 0, 0, '2025-05-27 18:44:46', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (3, '角色管理', 'SystemRole', '/sys/role', '/system/role/index', NULL, 'sys:role:list-page', 1, 0, NULL, 1, 5, 1, 0, 0, '2025-05-27 18:45:45', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (4, '菜单管理', 'SystemMenu', '/sys/menu', '/system/menu/index', NULL, 'sys:menu:list-tree', 1, 0, NULL, 1, 10, 1, 0, 0, '2025-05-27 18:46:33', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (5, '部门管理', 'SystemDept', '/sys/dept', '/system/dept/index', NULL, 'sys:dept:list-tree', 1, 0, NULL, 1, 15, 1, 0, 0, '2025-05-27 18:47:28', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (6, '字典管理', 'SystemDict', '/sys/dict', '/system/dict/index', NULL, 'sys:dict:list-page', 1, 0, NULL, 1, 20, 1, 0, 0, '2025-05-27 18:48:41', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (7, '参数配置', 'SystemParameter', '/sys/parameter', '/system/parameter/index', NULL, 'sys:parameter:list-page', 1, 0, NULL, 1, 25, 1, 0, 0, '2025-05-27 18:49:34', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (8, '系统日志', 'SystemLog', '/sys/log', NULL, 'carbon:catalog', NULL, 0, 0, NULL, 0, 5, 1, 0, 0, '2025-05-27 18:50:50', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (9, '登录日志', 'SystemLoginLog', '/sys/log/login', '/system/log/login/index', NULL, 'sys:login-log:list', 1, 0, NULL, 8, 0, 1, 0, 0, '2025-05-27 18:51:31', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (10, '操作日志', 'SystemOperateLog', '/sys/log/operate', '/system/log/operate/index', NULL, 'sys:operate-log:list', 1, 0, NULL, 8, 5, 1, 0, 0, '2025-05-27 18:52:29', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (11, '系统监控', 'SystemMonitor', '/sys/monitor', NULL, 'lucide:monitor', NULL, 0, 0, NULL, 0, 10, 1, 0, 0, '2025-05-27 18:53:23', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (12, '会话管理', 'SystemMonitorSession', '/sys/monitor/session', '/system/monitor/session/index', NULL, 'sys:session:list', 1, 0, NULL, 11, 0, 1, 0, 0, '2025-05-27 18:54:12', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (13, '列表', NULL, NULL, NULL, NULL, 'sys:user:list', 2, 0, NULL, 2, 0, 1, 0, 0, '2025-05-27 18:56:24', '2025-05-27 18:56:41');
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (14, '新增', NULL, NULL, NULL, NULL, 'sys:user:create', 2, 0, NULL, 2, 5, 1, 0, 0, '2025-05-27 18:57:05', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (15, '编辑', NULL, NULL, NULL, NULL, 'sys:user:update', 2, 0, NULL, 2, 10, 1, 0, 0, '2025-05-27 18:57:33', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (16, '密码重置', NULL, NULL, NULL, NULL, 'sys:user:password-reset', 2, 0, NULL, 2, 15, 1, 0, 0, '2025-05-27 18:58:11', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (17, '删除', NULL, NULL, NULL, NULL, 'sys:user:remove', 2, 0, NULL, 2, 20, 1, 0, 0, '2025-05-27 18:58:38', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (18, '列表', NULL, NULL, NULL, NULL, 'sys:role:list', 2, 0, NULL, 3, 0, 1, 0, 0, '2025-05-27 18:59:12', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (19, '新增', NULL, NULL, NULL, NULL, 'sys:role:create', 2, 0, NULL, 3, 5, 1, 0, 0, '2025-05-27 18:59:32', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (20, '编辑', NULL, NULL, NULL, NULL, 'sys:role:update', 2, 0, NULL, 3, 10, 1, 0, 0, '2025-05-27 18:59:56', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (21, '授权', NULL, NULL, NULL, NULL, 'sys:role:authority', 2, 0, NULL, 3, 15, 1, 0, 0, '2025-05-27 19:00:39', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (22, '删除', NULL, NULL, NULL, NULL, 'sys:role:remove', 2, 0, NULL, 3, 20, 1, 0, 0, '2025-05-27 19:01:15', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (23, '关联用户列表', NULL, NULL, NULL, NULL, 'sys:role:user-list-page', 2, 0, NULL, 3, 25, 1, 0, 0, '2025-05-27 19:01:51', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (24, '删除关联用户', NULL, NULL, NULL, NULL, 'sys:role:remove-user', 2, 0, NULL, 3, 30, 1, 0, 0, '2025-05-27 19:02:13', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (25, '列表', NULL, NULL, NULL, NULL, 'sys:menu:list', 2, 0, NULL, 4, 0, 1, 0, 0, '2025-05-27 19:04:44', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (26, '新增', NULL, NULL, NULL, NULL, 'sys:menu:create', 2, 0, NULL, 4, 5, 1, 0, 0, '2025-05-27 19:04:44', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (27, '编辑', NULL, NULL, NULL, NULL, 'sys:menu:update', 2, 0, NULL, 4, 10, 1, 0, 0, '2025-05-27 19:04:44', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (28, '删除', NULL, NULL, NULL, NULL, 'sys:menu:remove', 2, 0, NULL, 4, 15, 1, 0, 0, '2025-05-27 19:04:44', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (29, '列表', NULL, NULL, NULL, NULL, 'sys:dept:list', 2, 0, NULL, 5, 0, 1, 0, 0, '2025-05-27 19:06:29', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (30, '新增', NULL, NULL, NULL, NULL, 'sys:dept:create', 2, 0, NULL, 5, 5, 1, 0, 0, '2025-05-27 19:06:29', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (31, '编辑', NULL, NULL, NULL, NULL, 'sys:dept:update', 2, 0, NULL, 5, 10, 1, 0, 0, '2025-05-27 19:06:29', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (32, '删除', NULL, NULL, NULL, NULL, 'sys:dept:remove', 2, 0, NULL, 5, 15, 1, 0, 0, '2025-05-27 19:06:29', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (33, '新增', NULL, NULL, NULL, NULL, 'sys:dict:create', 2, 0, NULL, 6, 5, 1, 0, 0, '2025-05-27 19:08:10', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (34, '编辑', NULL, NULL, NULL, NULL, 'sys:dict:update', 2, 0, NULL, 6, 10, 1, 0, 0, '2025-05-27 19:08:10', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (35, '删除', NULL, NULL, NULL, NULL, 'sys:dict:remove', 2, 0, NULL, 6, 15, 1, 0, 0, '2025-05-27 19:08:10', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (36, '字典项-列表', NULL, NULL, NULL, NULL, 'sys:dict-item:list', 2, 0, NULL, 6, 20, 1, 0, 0, '2025-05-27 19:11:07', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (37, '字典项-分页列表', NULL, NULL, NULL, NULL, 'sys:dict-item:list-page', 2, 0, NULL, 6, 25, 1, 0, 0, '2025-05-27 19:11:07', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (38, '字典项-新增', NULL, NULL, NULL, NULL, 'sys:dict-item:create', 2, 0, NULL, 6, 30, 1, 0, 0, '2025-05-27 19:11:07', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (39, '字典项-编辑', NULL, NULL, NULL, NULL, 'sys:dict-item:update', 2, 0, NULL, 6, 35, 1, 0, 0, '2025-05-27 19:11:07', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (40, '字典项-删除', NULL, NULL, NULL, NULL, 'sys:dict-item:remove', 2, 0, NULL, 6, 40, 1, 0, 0, '2025-05-27 19:11:07', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (41, '新增', NULL, NULL, NULL, NULL, 'sys:parameter:create', 2, 0, NULL, 7, 5, 1, 0, 0, '2025-05-27 19:12:03', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (42, '编辑', NULL, NULL, NULL, NULL, 'sys:parameter:update', 2, 0, NULL, 7, 10, 1, 0, 0, '2025-05-27 19:12:03', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (43, '删除', NULL, NULL, NULL, NULL, 'sys:parameter:remove', 2, 0, NULL, 7, 15, 1, 0, 0, '2025-05-27 19:12:03', NULL);
INSERT INTO `sys_menu` (`id`, `title`, `name`, `path`, `component`, `icon`, `authority`, `menu_type`, `component_type`, `link`, `parent_id`, `sort`, `enable_status`, `cache_status`, `hidden_status`, `create_time`, `update_time`) VALUES (44, '强制下线', NULL, NULL, NULL, NULL, 'sys:session:forced-offline', 2, 0, NULL, 12, 0, 1, 0, 0, '2025-05-27 19:14:19', NULL);
COMMIT;

-- ----------------------------
-- Table structure for sys_operate_log
-- ----------------------------
DROP TABLE IF EXISTS `sys_operate_log`;
CREATE TABLE `sys_operate_log` (
                                   `id` bigint NOT NULL AUTO_INCREMENT,
                                   `title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '业务模块',
                                   `business_type` tinyint DEFAULT '0' COMMENT '业务类型',
                                   `user_id` bigint DEFAULT NULL COMMENT '用户 ID',
                                   `username` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '用户名',
                                   `nickname` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '用户昵称',
                                   `method` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '请求方法',
                                   `request_method` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '请求方式',
                                   `url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '请求地址',
                                   `ip` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT 'IP 地址',
                                   `request` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci COMMENT '请求体',
                                   `response` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci COMMENT '响应体',
                                   `status` tinyint DEFAULT '0' COMMENT '状态：0 成功 1 失败',
                                   `error_msg` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci COMMENT '错误信息',
                                   `take_time` bigint DEFAULT '0' COMMENT '耗时',
                                   `operate_time` datetime DEFAULT CURRENT_TIMESTAMP COMMENT '操作时间',
                                   `create_time` datetime DEFAULT CURRENT_TIMESTAMP,
                                   `update_time` datetime DEFAULT NULL,
                                   PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统操作日志';

-- ----------------------------
-- Records of sys_operate_log
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_parameter
-- ----------------------------
DROP TABLE IF EXISTS `sys_parameter`;
CREATE TABLE `sys_parameter` (
                                 `id` bigint NOT NULL AUTO_INCREMENT,
                                 `name` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '参数名称',
                                 `key` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '参数键',
                                 `value` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '参数值',
                                 `remark` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
                                 `enable_status` tinyint DEFAULT '0' COMMENT '启用状态：0 禁用 1 启用',
                                 `deleted` tinyint DEFAULT '0' COMMENT '逻辑删除：0 正常 1 删除',
                                 `create_time` datetime DEFAULT CURRENT_TIMESTAMP,
                                 `update_time` datetime DEFAULT NULL,
                                 PRIMARY KEY (`id`),
                                 UNIQUE KEY `key_unique` (`key`) USING BTREE COMMENT '参数键唯一索引',
                                 KEY `enable_status_idx` (`enable_status`) USING BTREE COMMENT '启用状态普通索引',
                                 KEY `deleted_idx` (`deleted`) USING BTREE COMMENT '逻辑删除普通索引'
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统参数表';

-- ----------------------------
-- Records of sys_parameter
-- ----------------------------
BEGIN;
INSERT INTO `sys_parameter` (`id`, `name`, `key`, `value`, `remark`, `enable_status`, `deleted`, `create_time`, `update_time`) VALUES (1, '默认密码', 'default_password', '888888', '系统默认密码，用于用户新增或重置密码', 1, 0, '2025-05-27 18:41:10', NULL);
COMMIT;

-- ----------------------------
-- Table structure for sys_role
-- ----------------------------
DROP TABLE IF EXISTS `sys_role`;
CREATE TABLE `sys_role` (
                            `id` bigint NOT NULL AUTO_INCREMENT,
                            `name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '角色名称',
                            `code` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '角色编码',
                            `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
                            `sort` int DEFAULT '0' COMMENT '排序',
                            `enable_status` tinyint DEFAULT '0' COMMENT '启用状态：0 禁用 1 启用',
                            `create_time` datetime DEFAULT CURRENT_TIMESTAMP,
                            `update_time` datetime DEFAULT NULL,
                            PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统角色表';

-- ----------------------------
-- Records of sys_role
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_role_menu
-- ----------------------------
DROP TABLE IF EXISTS `sys_role_menu`;
CREATE TABLE `sys_role_menu` (
                                 `role_id` bigint DEFAULT NULL COMMENT '角色 ID',
                                 `menu_id` bigint DEFAULT NULL COMMENT '菜单 ID'
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统角色菜单表';

-- ----------------------------
-- Records of sys_role_menu
-- ----------------------------
BEGIN;
COMMIT;

-- ----------------------------
-- Table structure for sys_user
-- ----------------------------
DROP TABLE IF EXISTS `sys_user`;
CREATE TABLE `sys_user` (
                            `id` bigint NOT NULL AUTO_INCREMENT,
                            `username` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '用户名',
                            `password` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '密码',
                            `nickname` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '昵称',
                            `avatar` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '头像',
                            `email` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '邮箱',
                            `dept_id` bigint DEFAULT NULL COMMENT '部门 ID',
                            `enable_status` tinyint DEFAULT '0' COMMENT '启用状态：0 禁用 1 启用',
                            `last_login_time` datetime DEFAULT NULL COMMENT '最后登陆时间',
                            `deleted` tinyint DEFAULT '0' COMMENT '逻辑删除：0 正常 1 删除',
                            `create_time` datetime DEFAULT CURRENT_TIMESTAMP,
                            `update_time` datetime DEFAULT NULL,
                            PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统用户表';

-- ----------------------------
-- Records of sys_user
-- ----------------------------
BEGIN;
INSERT INTO `sys_user` (`id`, `username`, `password`, `nickname`, `avatar`, `email`, `dept_id`, `enable_status`, `last_login_time`, `deleted`, `create_time`, `update_time`) VALUES (1, 'admin', '21218cca77804d2ba1922c33e0151105', '系统管理员', 'https://unpkg.com/@vbenjs/static-source@0.1.7/source/avatar-v1.webp', NULL, 1, 1, NULL, 0, '2025-05-27 18:42:10', NULL);
COMMIT;

-- ----------------------------
-- Table structure for sys_user_role
-- ----------------------------
DROP TABLE IF EXISTS `sys_user_role`;
CREATE TABLE `sys_user_role` (
                                 `user_id` bigint DEFAULT NULL,
                                 `role_id` bigint DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统用户角色表';

-- ----------------------------
-- Records of sys_user_role
-- ----------------------------
BEGIN;
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
